package com.ctshk.rpc.order.hotel.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ctshk.common.model.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;

/**
 * <p>
 * 酒店订单表
 * </p>
 *
 * @author yinhuan
 * @since 2021-03-08
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("t_hotel_order")
@ApiModel(value="HotelOrder对象", description="酒店订单表")
public class HotelOrder extends BaseEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "销售单号")
    private String orderNumber;

    @ApiModelProperty(value = "查询号码")
    private String inquiryNumber;

    @ApiModelProperty(value = "确认单号")
    private String confirmNumber;

    @ApiModelProperty(value = "API订单号")
    private String apiOrderNumber;

    @ApiModelProperty(value = "下单类型(1 散客,2 代理商,3 大客户)")
    private Integer ordersType;

    @ApiModelProperty(value = "酒店id")
    private Long hotelId;

    @ApiModelProperty(value = "房间id")
    private Long roomId;

    @ApiModelProperty(value = "酒店产品id")
    private Long hotelProductId;

    @ApiModelProperty(value = "酒店产品下单时的成本币种id")
    private Long costCurrencyId;

    @ApiModelProperty(value = "酒店产品下单时的成本币种名称")
    private String costCurrencyName;

    @ApiModelProperty(value = "酒店产品下单时的成本币种汇率")
    private Double costExchangeRate;

    @ApiModelProperty(value = "入住日期")
    private LocalDate checkInDate;

    @ApiModelProperty(value = "离店日期")
    private LocalDate checkOutDate;

    @ApiModelProperty(value = "含几晚")
    private Integer nights;

    @ApiModelProperty(value = "购买数量")
    private Integer number;

    @ApiModelProperty(value = "是否外挂单")
    private Integer isManual;

    @ApiModelProperty(value = "是否代理")
    private Integer isAgent;

    @ApiModelProperty(value = "代理公司id")
    private Long agencyId;

    @ApiModelProperty(value = "代理公司")
    private String agencyCompany;

    @ApiModelProperty(value = "代理人名称")
    private String agentUserName;

    @ApiModelProperty(value = "单价")
    private BigDecimal unitPrice;

    @ApiModelProperty(value = "订单金额")
    private BigDecimal orderAmount;

    @ApiModelProperty(value = "付款状态")
    private Integer paymentStatus;

    @ApiModelProperty(value = "预订状态")
    private Integer scheduledStatus;

    @ApiModelProperty(value = "取消状态")
    private Integer cancelStatus;

    @ApiModelProperty(value = "取消原因")
    private String cancelReason;

    @ApiModelProperty(value = "取消备注")
    private String cancelRemark;

    @ApiModelProperty(value = "产品类型")
    private Integer productType;

    @ApiModelProperty(value = "来源")
    private Integer source;

    @ApiModelProperty(value = "销售人员id")
    private Long salesmanId;

    @ApiModelProperty(value = "销售人员名称")
    private String salesmanName;

    @ApiModelProperty(value = "联系人姓")
    private String surname;

    @ApiModelProperty(value = "联系人名")
    private String name;

    @ApiModelProperty(value = "联系人姓名")
    private String contactName;

    @ApiModelProperty(value = "联系人手机")
    private String contactMobile;

    @ApiModelProperty(value = "联系人手机区号id")
    private Long contactMobileAreaCodeId;

    @ApiModelProperty(value = "联系人手机区号")
    private String contactMobileAreaCode;

    @ApiModelProperty(value = "联系人国籍")
    private String contactCountryId;

    @ApiModelProperty(value = "联系人国籍")
    private String contactCountryName;

    @ApiModelProperty(value = "称谓(1:先生;2:女士;3:小姐;4:男童;5:女童)")
    private Integer contactAppellation;

    @ApiModelProperty(value = "联系人邮箱")
    private String contactEmail;

    @ApiModelProperty(value = "支付时间")
    private LocalDateTime payTime;

    @ApiModelProperty(value = "付款到期时间")
    private LocalDateTime payExpireDate;

    @ApiModelProperty(value = "星赏会会员ID")
    private String memberId;

    @ApiModelProperty(value = "使用积分")
    private Integer usingPoints;

    @ApiModelProperty(value = "优惠卷id(无需此字段)")
    private Long couponId;

    @ApiModelProperty(value = "推广码")
    private String couponCode;

    @ApiModelProperty(value = "推广码减免金额")
    private BigDecimal couponDeduction;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "创建人")
    private Long createId;

    @ApiModelProperty(value = "修改人")
    private Long modifiedId;

    @ApiModelProperty(value = "删除标识")
    private Integer isDeleted;

    @ApiModelProperty(value = "性别")
    private Integer gender;

    @ApiModelProperty(value = "应收金额")
    private BigDecimal receivableAmount;

    @ApiModelProperty(value = "总实收")
    private BigDecimal receiptAmount;

    @ApiModelProperty(value = "已退款金额")
    private BigDecimal refundedAmount;

    @ApiModelProperty(value = "销售方式(1：单品销售 2：打包销售)")
    private Integer salesMethods;

    @ApiModelProperty(value = "城市")
    private String cityName;

    @ApiModelProperty(value = "酒店品牌")
    private String brandName;

    @ApiModelProperty(value = "酒店名称")
    private String hotelName;

    @ApiModelProperty(value = "房间名称")
    private String roomName;

    @ApiModelProperty(value = "酒店产品名称")
    private String hotelProductName;

    @ApiModelProperty(value = "是否含早")
    private Integer hasBreakfast;

    @ApiModelProperty(value = "会员查询类型(1:手机号查询,2:证件号码查询)")
    private Integer memberQueryType;

    @TableField(exist = false)
    @ApiModelProperty(value = "会员查询证件类型(根据CRM提供的证件类型列表)")
    private Integer memberQueryCertificatesType;

    @TableField(exist = false)
    @ApiModelProperty(value = "会员查询编码(根据memberQueryType判断)")
    private String memberQueryCode;

    @TableField(exist = false)
    @ApiModelProperty(value = "会员类型,枚举MemberType")
    private String memberType;

    @ApiModelProperty(value = "C端下单用户id")
    private Long userId;
}
